<template>
	<view>
		<u-sticky bgColor="#6492FF" offsetTop=0 customNavHeight=0>
			<navbox title="独立后台"></navbox>
		</u-sticky>
		<view class="con">
			<view class="con__item" v-for="(item,index) in list" :key="index">
				<view class="">
					<view class="" style="margin-bottom: 20rpx;">
						名称：{{item.name}}
					</view>
					<view class="" style="margin-bottom: 20rpx;">
						备注：{{item.note}}
					</view>
					<view class="u-flex u-flex-y-center" v-if='item.link'>
						地址：{{item.link}}
						<view class="con__item__copy" @click='copy(item.link)'>
							复制
						</view>
					</view>
					<view class="u-flex" v-if='item.qrcode' style="padding-top: 20rpx;">
						二维码:
						<image :src="item.qrcode" mode="widthFix" style="width: 180rpx;margin-left: 20rpx;" @click="imgPreview([item.qrcode],0)"></image>
					</view>
				</view>
				<view class="con__item__btn" v-if="item.link" @click="navto('/pages/my/web?link='+item.link)">
					查看
				</view>
			</view>
		</view>
	</view>
</template>

<script>
	import {platlist} from '@/api/home.js'
	export default {
		data() {
			return {
				list:[]
			};
		},
		onLoad() {
			platlist().then(res=>{
				if(res.data.code==200){
					this.list=res.data.data
				}
			})
		}
	}
</script>

<style lang="scss">
page{
	background-color: #f6f6f6;
}
.con{
	padding: 25rpx 16rpx;
	&__item{
		padding: 26rpx 30rpx 22rpx;
		margin-bottom: 25rpx;
		background: #FFFFFF;
		border-radius: 14rpx;
		font-family: Source Han Sans SC;
		font-weight: 400;
		font-size: 26rpx;
		color: #3E3D3D;
		line-height: 26rpx;
		display: flex;
		align-items: center;
		justify-content: space-between;
		&__copy{
			width: 61rpx;
			height: 31rpx;
			border-radius: 16rpx;
			border: 1rpx solid #707070;
			font-family: Source Han Sans SC;
			font-weight: 400;
			font-size: 17rpx;
			color: #707070;
			line-height: 17rpx;
			display: flex;
			align-items: center;
			justify-content: center;
			margin-left: 14rpx;
		}
		&__btn{
			width: 107rpx;
			height: 55rpx;
			background: #6492FF;
			border-radius: 17rpx;
			display: flex;
			align-items: center;
			font-family: Source Han Sans SC;
			font-weight: 400;
			font-size: 26rpx;
			color: #F6F6F6;
			line-height: 26rpx;
			justify-content: center;
		}
	}
}
</style>
